package com.zzyk.main.service;

import com.zzyk.main.configuration.exception.UserException;
import com.zzyk.main.model.pojo.SysRole;
import com.zzyk.main.model.pojo.UserRole;


import java.util.List;
import java.util.Set;

public interface ISysRoleService {
    public SysRole getRole(int roleId);

    public SysRole getRole(String roleName);

    public List<SysRole> getRoleList(SysRole sysRole);

    public int addRole(SysRole sysRole);

    public int updateRole(SysRole sysRole) throws UserException;

    public int deleteRole(int roleId);

    public int addUserRole(UserRole userRole);

    public int deleteUserRole(UserRole userRole);

    public int changeUserRole(Integer userId, Integer roleId);

    public Set<SysRole> getRoleSetByUserId(int userId,boolean permission);

    List<SysRole> getOrdinaryRole();
}
